﻿%text-overflow-mission {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

:root {
    --high-color: #d73403;
    --medium-color: #ffa500;
    --low-color: #90ee90;
}

.container {
    background: {
        image: url('https://api.ghser.com/random/pe.php');
        color: white;
        position: center top;
        repeat: no-repeat;
        size: cover;
    }
}

li {
    list-style: none;
}

body {
    display: flex;
    height: 100%;
    flex-direction: column;
    justify-content: space-around;
}

.box {
    margin: 20px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.45);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-weight: 700;
}

.tb {
    display: flex;
    justify-content: center;
    align-items: center;

    .avatar {
        position: relative;
        height: 100px;
        width: 100px;
        border-radius: 50%;
        margin-right: 20px;

        img {
            width: 100%;
            border-radius: 50%;
        }

        &::before {
            content: '';
            position: absolute;
            inset: 0;
            z-index: -1;
            margin: -3px;
            border-radius: 50%;
            box-shadow: 1px 1px 3px 0 #000;
            background: linear-gradient(135deg, #fff1eb, #ace0f9);
        }
    }
}

hr {
    border: 0;
    height: 2px;
    background-image: linear-gradient(135deg, #bdc3c7 10%, #2c3e50);
    border-radius: 10px;
}

.header {
    max-width: 100%;
    overflow: hidden;

    hr {
        margin: 5px 0px;
    }

    p {
        font-size: 12px;
        color: #2f4f4f;
    }

    h1 {
        @extend %text-overflow-mission;
        display: inline-block;
        background-image: linear-gradient(271.14deg,
                #001bff 0.98%,
                #00f0ff 25.79%,
                #fce84a 47.33%,
                #f34628 65.77%,
                #b275ff 91.4%);
        background-clip: text;
        color: transparent;
    }
}

.info {
    width: 100%;
    display: flex;
    justify-content: space-around;
    font-weight: 700;

    .li {
        article {
            width: 100px;
            text-align: center;

            summary {
                font-size: 20px;
                margin-top: 5px;
            }

            p {
                font-size: 12px;
                color: #2f4f4f;
                white-space: nowrap;
            }
        }
    }
}

.cpu {
    width: 100px;
    height: 100px;
    background: #eee;
    position: relative;
    border-radius: 50%;
}

.left,
.right {
    width: 50px;
    height: 100px;
    position: absolute;
    overflow: hidden;
}

.right {
    right: 0;

    .right-circle {
        border-top-right-radius: 100px;
        border-bottom-right-radius: 100px;
        transform: rotate(180deg);
        transform-origin: left center;
    }
}

.left .left-circle,
.right .right-circle {
    width: 50px;
    height: 100px;
    background: #90ee90;
}

.left {
    .left-circle {
        border-top-left-radius: 100px;
        border-bottom-left-radius: 100px;
        transform: rotate(-180deg);
        transform-origin: right center;
    }
}

.inner {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    text-align: center;
    line-height: 75px;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    color: #999;
    font-size: 20px;
    background: white;
}

.memory {
    li {
        margin: 10px;
        display: flex;
    }

    hr {
        margin-bottom: 10px;
    }

    .progress {
        flex: 1;
        height: 25px;
        background: #c1c1c1;
        margin: 0 5px;
        position: relative;
        border-radius: 5px;

        .current {
            background: #90ee90;
            height: 25px;
            border-radius: 5px;
        }

        .word {
            position: absolute;
            line-height: 25px;
            left: 50%;
            transform: translate(-50%, 0);
            white-space: nowrap;
        }
    }
}

.HardDisk_li {
    .mount {
        @extend %text-overflow-mission;
        min-width: 15px;
        max-width: 3em;
        line-height: 25px;
        text-align: left;
    }

    .percentage {
        min-width: 2em;
        line-height: 25px;
        text-align: center;
    }
}

.speed {
    width: 100%;
    display: flex;
    height: 25px;
    line-height: 25px;

    p {
        @extend %text-overflow-mission;

        &:first-child {
            flex-grow: 1;
            flex-shrink: 0;
            max-width: 50%;
            text-align: left;
            margin-right: 20px;
        }

        &:last-child {
            flex-grow: 1;
            flex-shrink: 1;
            margin-left: 20px;
            text-align: right;
        }
    }
}